package ch3;

import java.util.Scanner;

public class Race2 {

	public static void main(String[] args) {
		// 用多重if代替嵌套if
		Scanner in = new Scanner(System.in);
		System.out.println("请输入百米成绩：");
		double c = in.nextDouble();
		System.out.println("请确认性别：");
		String sex = in.next();
		if (c <= 10 && sex.equals("男")) {
			System.out.println("男子组决赛");
		} else if (c <= 10 && sex.equals("女")) {
			System.out.println("女子组决赛");
		} else {
			System.out.println("淘汰了");
		}
	}

}
